Consumers continue to demand more functionality and higher performance in their battery-operated products, such as smart phones and electronic tablet computers. To maximize functionality and battery life, developers of these battery-powered applications must consider several factors in their system design. In these applications, the microcontroller is a primary power consumer and developers must carefully consider the way energy is used. In some cases, developers may need to measure ultra-low power consumption of the microcontroller while in sleep mode. Traditional solutions for measuring power consumption use external current measuring circuitry. It is difficult, however, to design measuring circuitry that can measure in the nanoamp (nA) range.